DataGrid - Pager - Show correct pageIndex when virtualScrolling is enabled on pageSize change#33412
Open
Tucchhaa wants to merge 2 commits intoDevExpress:26_1from
Open
DataGrid - Pager - Show correct pageIndex when virtualScrolling is enabled on pageSize change#33412Tucchhaa wants to merge 2 commits intoDevExpress:26_1from
Tucchhaa wants to merge 2 commits intoDevExpress:26_1from
Conversation
0b6a17d to
664a129
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes DataGrid pager’s displayed page index when switching the page size to “all” (internally pageSize = 0) while virtual scrolling is enabled, ensuring the pager info shows a valid “Page 1 of 1 …” state.
Changes:
- Adjust pager page index calculation to handle
pageSize === 0(the “all items” mode). - Add a TestCafe e2e regression test covering the virtual-scrolling + pageSize “all” scenario.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| packages/devextreme/js/__internal/grids/grid_core/pager/m_pager.ts | Ensures pager’s 1-based pageIndex is correct when pageSize is set to 0 (“all”). |
| e2e/testcafe-devextreme/tests/dataGrid/common/pager.ts | Adds regression test verifying pager info becomes “Page 1 of 1 …” after switching to “all” with virtual scrolling. |
Tucchhaa
commented
Apr 28, 2026
| @@ -9,6 +9,10 @@ const PAGER_CLASS = 'pager'; | |||
| export const MAX_PAGES_COUNT = 10; | |||
|
|
|||
| const getPageIndex = function (dataController) { | |||
Contributor
Author
There was a problem hiding this comment.
This function is used to get visible index of the current page, that is passed to pager so it could display it.
If in pager the pageSize 'all' is selected, then dataController.pageSize() == 0, and so there's only one page.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.